/*
~   Copyright (c) WSO2 Inc. (http://wso2.com) All Rights Reserved.
~
~   Licensed under the Apache License, Version 2.0 (the "License");
~   you may not use this file except in compliance with the License.
~   You may obtain a copy of the License at
~
~        http://www.apache.org/licenses/LICENSE-2.0
~
~   Unless required by applicable law or agreed to in writing, software
~   distributed under the License is distributed on an "AS IS" BASIS,
~   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~   See the License for the specific language governing permissions and
~   limitations under the License.
*/

/* ========================================================================
 * methods/mixins
 * ======================================================================== */

@mixin clearfix {
    &:after {
        content: " ";
        display: block;
        font-size: 0;
        height: 0;
        clear: both;
        visibility: hidden;
    }
}

@mixin border-radius($val: 0) {
    -webkit-border-radius: $val;
    -moz-border-radius: $val;
    border-radius: $val;
}

@mixin box-shadow($val: none) {
    -webkit-box-shadow: $val;
    -moz-box-shadow: $val;
    box-shadow: $val;
}

@mixin transform($val) {
    -webkit-transform: $val;
    -moz-transform: $val;
    -ms-transform: $val;
    -o-transform: $val;
    transform: $val;
}

@mixin transition($val) {
    -webkit-transition: $val;
    -moz-transition: $val;
    -ms-transition: $val;
    -o-transition: $val;
    transition: $val;
}

@mixin gradient($origin: top, $start: #ffffff, $stop: #e4e4e4) {
    background-color: $start;
    background-image: -webkit-linear-gradient($origin, $start, $stop);
    background-image: -moz-linear-gradient($origin, $start, $stop);
    background-image: -o-linear-gradient($origin, $start, $stop);
    background-image: -ms-linear-gradient($origin, $start, $stop);
    background-image: linear-gradient($origin, $start, $stop);
}

@mixin font($font, $font-weight, $font-style, $font-name, $file-name, $font-folder-path){
    $font-file: '#{$font-folder-path}/#{$font}/#{$file-name}';
    @font-face {
        font-family: $font;
        font-weight: $font-weight;
        font-style: $font-style;
        src: url('#{$font-file}.eot');
        src: url('#{$font-file}.eot?#iefix') format('embedded-opentype'),
        local($font-name),
        local($file-name),
        url('#{$font-file}.woff2') format('woff2'),
        url('#{$font-file}.woff') format('woff'),
        url('#{$font-file}.ttf') format('truetype'),
        url('#{$font-file}.svg##{$font}') format('svg');
    }
}

@mixin square-ratio($width, $height) {
    position: relative;

    &:before {
        display: block;
        content: "";
        width: 100%;
        padding-top: ($height / $width) * 100%;
    }
    > .square-element {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }
}

@mixin fade-color($color: #ffffff) {
    &:after {
        content: "";
        background-image: -webkit-gradient(linear, left top, right top, color-stop(0%, fade($color, 0%)), color-stop(100%, fade($color, 100%)));
        background-image: -webkit-linear-gradient(left, fade($color, 0%), fade($color, 100%));
        background: linear-gradient(to right, fade($color, 0%), fade($color, 100%));
        filter: progid:DXImageTransform.Microsoft.gradient(GradientType=1, StartColorStr='#00$color', EndColorStr='$color');
        bottom: 0;
        max-height: 100%;
        position: absolute;
        right: 0;
        height: 10000px;
        width: 60px;
    }
}

@mixin opacity($opacity) {
    opacity: $opacity;
    // IE8 filter
    $opacity-ie: ($opacity * 100);
    filter: "alpha(opacity=#{$opacity-ie})";
}

@mixin placeholder($color) {
    &::-moz-placeholder { color: $color; } // Firefox
    &:-ms-input-placeholder { color: $color; } // Internet Explorer 10+
    &::-webkit-input-placeholder { color: $color; } // Safari and Chrome
}

@mixin reset-default() {
    padding: 0;
    margin: 0;
    list-style: none;
}

/* ========================================================================
 * default values
 * ======================================================================== */

$font-folder-path: '../fonts';
@include font( 'Roboto', 400, 'normal', 'Roboto Regular', 'Roboto-Regular', $font-folder-path);
$font-default: 'Roboto', Arial, Helvetica, sans-serif;
$font-default-weight: 300;
$font-icons: 'font-wso2';
$screen-sizes: (
    xs:'(max-width:767px)',
    sm:'(min-width:768px) and (max-width:991px)',
    md:'(min-width:992px) and (max-width:1199px)',
    lg:'(min-width:1200px)'
);
$sides: top, bottom, left, right;
$message-status: info, success, warning, danger;
$sizes-length: 5;
$default-gap: 5px;

$base-dark-color: #222;
$base-light-color: #ffffff;
$base-success-color: #5cb85c;
$base-info-color: #009DA7;
$base-warning-color: #f0ad4e;
$base-danger-color: #d9534f;

$primary-color: #715C4C;
$secondary-color: #e4e4e4;
$optional-color: #DA762B;

$header-background-color: #463A31;
$header-height: 50px;
$header-link-hover-background-color: darken($header-background-color, 10%);

$breadcrumb-background-color: #282828;
$breadcrumb-color: $base-light-color;
$breadcrumb-height: 30px;
$breadcrumb-padding: 5px 15px;

$navbar-height: 50px;
$navbar-padding: 0 15px;
$navbar-color1: #4D5461;
$navbar-background-color: $primary-color;
$navbar-link-color: $base-light-color;
$navbar-hover-link-color: $navbar-link-color;
$navbar-link-background-color: $navbar-color1;
$navbar-link-hover-background-color: lighten($navbar-background-color, 10%);

$navbrand-background-color: darken($navbar-background-color, 10%);

$page-content-wrapper-height: calc(100% - 130px);
$page-content-wrapper-height-mobile: calc(100% - 205px);
$page-content-wrapper-sidebar-height-mobile: calc(100% - 245px);

$footer-height: 40px;
$footer-background: #272c30;
$footer-color: #cbcbcb;

$inverse-layout-background: $primary-color;
$inverse-layout-color: $base-light-color;

$loading-background-opacity: 0.6;
$loading-background-color: $base-dark-color;
$loading-color: $base-light-color;
$loading-inverse-background-color: $base-light-color;
$loading-inverse-color: $base-dark-color;
$loading-image-icon-max-width: 50px;

$dropdown-menu-dark-background-color: $base-dark-color;
$dropdown-menu-dark-color: $base-light-color;
$dropdown-menu-dark-tiles-background-color: #444;
$dropdown-menu-dark-tiles-hover-background-color: #555;
$dropdown-menu-dark-tiles-color: $base-light-color;

$button-default-background-color: $base-light-color;
$button-default-color: $base-dark-color;
$button-default-hover-background-color: darken($button-default-background-color, 10%);
$button-default-border-color: $button-default-background-color;
$button-default-hover-border-color: $button-default-background-color;

$button-primary-background-color: $primary-color;
$button-primary-color: $base-light-color;
$button-primary-hover-background-color: lighten($button-primary-background-color, 10%);
$button-primary-border-color: $button-primary-background-color;
$button-primary-hover-border-color: $button-primary-background-color;

$switch-active-background-color: #25262b;
$switch-inactive-background-color: #a6a6a6;
$switch-disabled-background-color: #6f7579;
$switch-handler-active-color: #237bd5;
$switch-handler-inactive-color: #eaeaea;
$switch-handler-disabled-color: #484e52;

$form-control-max-width: 750px;
$sidebar-width-default: 350px;

/* ========================================================================
 * loading fonts
 * ======================================================================== */

//@include font( 'Roboto', 100, 'normal', 'Roboto Thin', 'Roboto-Thin', $font-folder-path)
//@include font( 'Roboto', 300, 'normal', 'Roboto Light', 'Roboto-Light', $font-folder-path)
//@include font( 'Roboto', 400, 'normal', 'Roboto Regular', 'Roboto-Regular', $font-folder-path)
//@include font( 'Roboto', 500, 'normal', 'Roboto Medium', 'Roboto-Medium', $font-folder-path)
//@include font( 'Roboto', 700, 'normal', 'Roboto Bold', 'Roboto-Bold', $font-folder-path)
//@include font( 'Roboto', 900, 'normal', 'Roboto Black', 'Roboto-Black', $font-folder-path)
//@include font( 'Roboto', 100, 'italic', 'Roboto Thin Italic', 'Roboto-Thin-Italic', $font-folder-path)
//@include font( 'Roboto', 300, 'italic', 'Roboto Light Italic', 'Roboto-Light-Italic', $font-folder-path)
//@include font( 'Roboto', 400, 'italic', 'Roboto Italic', 'Roboto-Italic', $font-folder-path)
//@include font( 'Roboto', 500, 'italic', 'Roboto Medium Italic', 'Roboto-Medium-Italic', $font-folder-path)
//@include font( 'Roboto', 700, 'italic', 'Roboto Bold Italic', 'Roboto-Bold-Italic', $font-folder-path)
//@include font( 'Roboto', 900, 'italic', 'Roboto Black Italic', 'Roboto-Black-Italict', $font-folder-path)

/* ========================================================================
 * icon styles
 * ======================================================================== */

.icon-success { color: $base-success-color }
.icon-info { color: $base-info-color }
.icon-warning { color: $base-warning-color }
.icon-danger { color: $base-danger-color }

[aria-expanded='true'] > .icon.fw-stack > .toggle-icon,
[aria-expanded='true'] > .icon.toggle-icon {
    &-up:before {
        content: '\e684';
    }
    &-down:before {
        content: '\e685';
    }
    &-left:before {
        content: '\e686';
    }
    &-right:before {
        content: '\e687';
    }
    &-up-arrow:before {
        content: '\e688';
    }
    &-down-arrow:before {
        content: '\e689';
    }
    &-left-arrow:before {
        content: '\e68a';
    }
    &-right-arrow:before {
        content: '\e68b';
    }
}

//.icon-grid {
//    &:extend(.fw all);
//    &:extend(.fw-grid all);
//}

/* ========================================================================
 * document styles
 * ======================================================================== */

* {
    outline: none !important;
}

html {
    position: relative;
    min-height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    width: 100%;
}

body {
    color: $base-dark-color;
    margin-bottom: $footer-height;
    font-family: $font-default;
    font-weight: $font-default-weight;
    width: 100%;
    overflow-x: hidden;
}

body > .page-content-wrapper > .container,
body > .page-content-wrapper > .container-fluid {
    padding: 20px 20px 60px;
    margin: 0;
}

@media only screen and (min-width: 768px) {
    body > .page-content-wrapper > .container,
    body > .page-content-wrapper > .container-fluid {
        padding: 3% 4% 4%;
        margin: 0;
    }
}

body.inverse {
    background: $inverse-layout-background;
    color: $inverse-layout-color;
}

a, a:hover, a:focus, a:active {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.h1, .h2, .h3, .h4, .h5, .h6,
h1, h2, h3, h4, h5, h6 {
    font-weight: 300;
}

br.spacer {
    display: block;
    line-height: 30px;
}

pre {
    @include border-radius;
    border: none;
}

.well {
    @include border-radius;
    @include box-shadow;
    border: none;
}

.badge {
    margin-bottom: 5px;
    padding: 4px 7px;
}

.no-wrap {
    white-space: nowrap;
}

.fade-edge {
    @include fade-color;
}

body.inverse .fade-edge {
    @include fade-color($inverse-layout-background);
}

.visible-block {
    display: block !important;
}

.visible-inline {
    display: inline !important;
}

.visible-inline-block {
    display: inline-block !important;
}

@for $i from 1 through $sizes-length {

    .add-padding-#{$i}x {
        padding: ($i * $default-gap) !important;
    }
    @each $side in $sides {
        .add-padding-#{$side}-#{$i}x {
            padding-#{$side}: ($i * $default-gap) !important;
        }
    }

    .add-margin-#{$i}x {
        margin: ($i * $default-gap) !important;
    }
    @each $side in $sides {
        .add-margin-#{$side}-#{$i}x {
            margin-#{$side}: ($i * $default-gap) !important;
        }
    }

}

.remove-padding {
    padding: 0 !important;

    &-top {
        padding-top: 0 !important;
    }
    &-bottom {
        padding-bottom: 0 !important;
    }
    &-left {
        padding-left: 0 !important;
    }
    &-right {
        padding-right: 0 !important;
    }
}

.remove-margin {
    margin: 0 !important;

    &-top {
        margin-top: 0 !important;
    }
    &-bottom {
        margin-bottom: 0 !important;
    }
    &-left {
        margin-left: 0 !important;
    }
    &-right {
        margin-right: 0 !important;
    }
}

@each $screen, $size in $screen-sizes {
    @media #{$size} {
        .remove-max-width-#{$screen} {
            max-width: none !important;
        }
        .remove-max-height-#{$screen} {
            max-width: none !important;
        }
        .pull-left-#{$screen} {
            float: left !important;
        }
        .pull-right-#{$screen} {
            float: right !important;
        }
        .float-remove-#{$screen} {
            float: none !important;
        }
        .text-center-#{$screen} {
            text-align: center !important;
        }
        .position-static-#{$screen} {
            position: static !important;
        }
        .remove-padding-#{$screen} {
            padding: 0 !important;
        }
        .remove-margin-#{$screen} {
            margin: 0 !important;
        }
        .fade-in-#{$screen} {
            opacity: 1 !important;
        }
        .fade-out-#{$screen} {
            opacity: 0 !important;
        }
        .display-none-#{$screen} {
            display: none !important;
        }
        .display-block-#{$screen} {
            display: block !important;
        }
        .display-inline-#{$screen} {
            display: inline !important;
        }
        .display-inline-block-#{$screen} {
            display: inline-block !important;
        }
    }
}

/* ========================================================================
 * row/col styles
 * ======================================================================== */

.row.no-gutter {
    margin-right: 0;
    margin-left: 0;
}

.row.no-gutter [class*='col-']:not(:first-child),
.row.no-gutter [class*='col-']:not(:last-child) {
    padding-right:0;
    padding-left:0;
}

.col-fixed-fill {
    overflow: hidden;
}

.col-fixed-left {
    float: left;
}

.col-fixed-right {
    float: right;
}

.col-fixed {
    &-1x {
        width: 50px;
    }
    &-2x {
        width: 100px;
    }
    &-3x {
        width: 200px;
    }
    &-4x {
        width: 300px;
    }
}

@media only screen and (max-width: 768px) {
    .col-fixed {
        &-1x {
            width: 25px;
        }
        &-2x {
            width: 50px;
        }
        &-3x {
            width: 100px
        }
        &-4x {
            width: 150px;
        }
    }
}

@media only screen and (max-width: 480px) {
    .col-fixed {
        &-1x {
            width: 12px;
        }
        &-2x {
            width: 25px;
        }
        &-3x {
            width: 50px;
        }
        &-4x {
            width: 75px;
        }
    }
}

/* ========================================================================
 * header styles
 * ======================================================================== */

header {
    background: $header-background-color;
    min-height: $header-height;
    position: relative;
}

header .brand {
    padding: 10px 0;

    & img.logo {
        height: 24px;
    }
    & a {
        min-height: 24px;
    }
    & h1 {
        display: inline-block;
        line-height: 1;
        font-weight: 300;
        font-size: 17px;
        margin: 0 0 0 5px;
        color: $base-light-color;
        padding: 6px 0 0 0;
        font-style: normal;
        text-transform: uppercase;
    }
}

header .auth {
    margin: 0 -15px;
}

header .dropdown {
    display: inline-block;
    color: $base-light-color;
    padding: 6px 0;
    min-height: $header-height;
}

header .dropdown[aria-expanded=true], header .dropdown:hover {
    background: $header-link-hover-background-color;
}

@media only screen and (max-width: 768px) {
    header .brand img.logo {
        margin-top: 15px;
    }

    header .brand h1 {
        display: block;
        line-height: 0.6;
    }
}

/* ========================================================================
 * navbar styles
 * ======================================================================== */

.navbar-wrapper {
    min-height: 50px;
}

.navbar.affix, .navbar.affix-bottom {
    top: 0 !important;
    width: 100%;
    z-index: 100000000;
}

@media (max-width:767px){
    .navbar.affix, .navbar.affix-bottom {
        position: static;
    }
}

.loading .navbar.affix {
    z-index: 1000000;
}

.navbar {
    background: $navbar-background-color;
    border: none;
    margin-bottom: 0;
    @include border-radius;
}

.navbar .container-fluid {
    padding: 0;
}

.navbar .container-fluid > .navbar-collapse,
.navbar .container-fluid > .navbar-header,
.navbar .container > .navbar-collapse,
.navbar .container > .navbar-header {
    padding: 0;
    margin: 0;

    & .icon {
        margin-bottom: 4px;
    }
}

.navbar-nav {
    margin: 7.5px 0;
}

@media (min-width:768px){
    .navbar-nav {
        margin: 0 0;
    }
}

.navbar-nav.nav-stacked > li {
    float: none !important;
}

.navbar-menu-toggle {
    float: left;
    height: $navbar-height;
    padding: 0 8px;
    line-height: $navbar-height;
    font-size: 18px;
    background: $optional-color;
    color: $base-light-color;

    &:hover, &:focus, &:active {
        color: $base-light-color;
        background: darken($optional-color, 10%);
    }
    &[aria-expanded=true] {
        background: darken($optional-color, 8%);
    }
    & .icon {
        line-height: $navbar-height;
    }
}

.navbar-toggle {
    border: none;
    @include border-radius;
}

.navbar > .container .navbar-brand,
.navbar > .container-fluid .navbar-brand {
    color: $base-light-color;
    margin-left: 0;
    padding: 0 15px;
    line-height: $navbar-height;
    text-transform: uppercase;
    background: $navbrand-background-color;
}

.navbar > .container .navbar-brand a,
.navbar > .container-fluid .navbar-brand a {
    color: $base-light-color;
    font-size: 16px;
}

.navbar-default .navbar-collapse, .navbar-default .navbar-form {
    border-top: none;
    @include box-shadow;
}

.navbar-default .navbar-nav > li a {
    color: $navbar-link-color;
    text-transform: uppercase;
    padding: 0 15px;
    line-height: $navbar-height;
    position: relative;
}

.navbar-default .navbar-nav > li a {
    &:hover, &:focus, &:active {
        background: $navbar-link-hover-background-color;
        color: $navbar-hover-link-color;
    }
    &:hover {
        background: $navbar-link-hover-background-color;
    }
}

.navbar-default .navbar-nav > .active > a {
    &, &:hover, &:focus, &:active {
        background: $navbar-link-hover-background-color;
        color: $navbar-hover-link-color;
    }
    &:hover {
        background: $navbar-link-hover-background-color;
    }
}

.navbar-collapse.dropdown {
    background: $dropdown-menu-dark-background-color;
    margin-right: -10px;
    margin-left: -10px;
    padding-bottom: 0;
    display: none !important;
    overflow: hidden !important;
}

.navbar-collapse.dropdown.collapsing {
    display: block !important;
}

.navbar-collapse.dropdown.in {
    display: block !important;
    overflow: visible !important;
}

.navbar-collapse.tiles ul.nav {
    height: 140px;
}

.navbar-collapse.tiles ul.nav li {
    display: inline-block;
    text-align: center;
    margin: 10px 5px;
}

.navbar-collapse.tiles ul.nav li a {
    text-decoration: none;
    width: 120px;
    height: 120px;
    padding: 15px;
    background: $dropdown-menu-dark-tiles-background-color;
    display: block;
    overflow: hidden;
    line-height: 1.4em;
}

.navbar-collapse.tiles ul.nav li li a {
    background: lighten($dropdown-menu-dark-tiles-background-color, 20%);
}

.navbar-collapse.tiles ul.nav li a:hover {
    background: $dropdown-menu-dark-tiles-hover-background-color;
}

.navbar-collapse.tiles ul.nav li li a:hover {
    background: lighten($dropdown-menu-dark-tiles-hover-background-color, 20%);
}

.navbar-collapse.tiles ul.nav li a i {
    font-size: 46px;
    display: block;
    margin-bottom: 10px;
}

.navbar-collapse.tiles ul.nav li ul {
    padding-left: 140px;
    margin-top: -130px;
    display: none;
}

.navbar-collapse.tiles ul.nav li.has-sub > a:after {
    width: 7px;
    height: 120px;
    background: #757575;
    display: inline-block;
    content: " ";
    top: 0;
    right: 0;
    z-index: 100000;
    position: absolute;
}

.navbar-collapse.tiles ul.nav li.has-sub[aria-expanded=true] > a:after {
    right: auto;
    left: 0;
}

.navbar-collapse.tiles ul.nav li.has-sub > a:before {
    display: inline-block;
    width: 0;
    height: 0;
    top: 45%;
    right: 1px;
    position: absolute;
    z-index: 1000000;
    content: " ";
    vertical-align: middle;
    border-left: 4px dashed;
    border-top: 4px solid\9;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    color: #dadada;
}

.navbar-collapse.tiles ul.nav li.has-sub[aria-expanded=true] > a:before {
    right: auto;
    left: -3px;
    border-right: 4px dashed;
    border-left: 4px dashed transparent;
}

.navbar-collapse.tiles ul.nav li > ul > li {

}

.nav-pills > li.active > a {
    &,
    &:focus,
    &:hover {
        color: $base-light-color;
        background: $primary-color;
        border-color: $primary-color;
    }
}

/* ========================================================================
 * sidebar styles
 * ======================================================================== */

.page-content-wrapper, .page-content-wrapper[data-container-behaviour=static] {
    position: relative;
    left: 0;
    margin-left: 0;
    min-height: $page-content-wrapper-height;
    @include transition(all 0.5s ease);
}

.page-content-wrapper.fixed,
.page-content-wrapper.fixed > div,
.page-content-wrapper.fixed > .sidebar-wrapper {
    max-height: $page-content-wrapper-height;
    overflow-y: auto;
    overflow-x: hidden;
}

.page-content-wrapper.fixed,
.page-content-wrapper.fixed > .sidebar-wrapper {
    max-height: 100%;
}

@media (max-width:767px){
    .page-content-wrapper {
        min-height: $page-content-wrapper-height-mobile;
    }
    .page-content-wrapper.fixed,
    .page-content-wrapper.fixed > div {
        max-height: $page-content-wrapper-height-mobile;
    }
    .page-content-wrapper.fixed > .sidebar-wrapper {
        max-height: 100%;
    }
}

.page-content-wrapper[data-container-push=true] {
    left: $sidebar-width-default;
}

.page-content-wrapper[data-push-side=right][data-container-push=true] {
    left: auto;
    right: $sidebar-width-default;
}

.page-content-wrapper[data-container-divide=true] {
    margin-left: $sidebar-width-default;
}

.page-content-wrapper[data-divide-side=right][data-container-divide=true] {
    margin-left: auto;
    padding-right: $sidebar-width-default;
}

.sidebar-wrapper {
    z-index: 1000;
    position: absolute;
    left: -$sidebar-width-default;
    width: $sidebar-width-default;
    height: 100%;
    overflow-y: auto;
    background: $base-dark-color;
    color: $base-light-color;
    @include transition(all 0.5s ease);
}

.sidebar-wrapper.affix {
    position: fixed;
    top: 50px;
}

.sidebar-wrapper.inverse {
    background: $base-light-color;
    color: $base-dark-color;
}

.sidebar-wrapper[data-side=right] {
    left: auto;
    right: -$sidebar-width-default;
}

.sidebar-wrapper.toggled {
    left: 0;
    right: auto;
}

.sidebar-wrapper[data-side=right].toggled {
    left: auto;
    right: 0;
}

ul.sidebar-messages {
    @include reset-default;
    padding: 10px;
}

ul.sidebar-messages > li {
    margin: 15px 0;
}

.sidebar-messages .message {
    background: none;
    padding: 5px 10px;
}

.sidebar-nav {
    position: absolute;
    top: 0;
    width: $sidebar-width-default;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sidebar-nav li {
    text-indent: 20px;
    line-height: 40px;
}

.sidebar-nav li a {
    display: block;
    text-decoration: none;
    color: #999999;
}

.sidebar-nav li a:hover {
    text-decoration: none;
    color: $base-light-color;
    background: rgba(255,255,255,0.2);
}

.sidebar-nav li a:active,
.sidebar-nav li a:focus {
    text-decoration: none;
}

.sidebar-nav > .sidebar-brand {
    height: 65px;
    font-size: 18px;
    line-height: 60px;
}

.sidebar-nav > .sidebar-brand a {
    color: #999999;
}

.sidebar-nav > .sidebar-brand a:hover {
    color: $base-light-color;
    background: none;
}

@media(min-width:768px) {
    #wrapper {
        padding-left: 250px;
    }

    #wrapper.toggled {
        padding-left: 0;
    }

    #sidebar-wrapper {
        width: $sidebar-width-default;
    }

    #wrapper.toggled #sidebar-wrapper {
        width: 0;
    }

    #page-content-wrapper {
        position: relative;
    }

    #wrapper.toggled #page-content-wrapper {
        position: relative;
        margin-right: 0;
    }
}

/* ========================================================================
 * breadcrumb styles
 * ======================================================================== */

.breadcrumb {
    margin: 0;
    overflow: hidden;
    text-transform: uppercase;
    background: $breadcrumb-background-color;
    color: $breadcrumb-color;
    min-height: $breadcrumb-height;
    padding: $breadcrumb-padding;
    @include border-radius;
}

.breadcrumb > li + li:before {
    padding: 0 1px;
}

.breadcrumb > li > a > .icon {
    padding-bottom: 3px;
}

/* ========================================================================
 * footer styles
 * ======================================================================== */

footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    min-height: $footer-height;
    overflow: hidden;
    color: $footer-color;
    background: $footer-background;
    z-index: 1000;
}

footer > .container,
footer > .container-fluid {
    padding-right: 15px;
    padding-left: 15px;
}

footer > .container p,
footer > .container-fluid p {
    line-height: $footer-height;
    margin-bottom: 0;
}

footer .icon {
    font-size: 37px;
    vertical-align: middle;
    color: $footer-color;
}

footer a {
    &, &:hover {
        color: $footer-color;
    }
}

/* ========================================================================
 * body styles
 * ======================================================================== */

.body-wrapper a:hover {
    text-decoration: underline;
}

.page-header {
    margin: 0 0 20px;
}

.page-header > h1 {
    margin-top: 0;
}

.lead {
    margin-bottom: 0;
}

/* ========================================================================
 * alert styles
 * ======================================================================== */

.alert {
    @include border-radius;
    border: none;
    position: relative;
    padding: 15px 50px 15px 15px;
}
.alert .icon {
    padding-bottom: 3px;
    margin-right: 6px;
}

.alert {
    & .close {
        position: absolute;
        top: 0;
        right: 0;
        height: 50px;
        width: 50px;
        line-height: 1;
        padding: 0 10px;
        font-size: 12px;
        background: $base-dark-color;
        color: $base-light-color;
    }
    &.alert-success {
        color: $base-light-color;
        background: $base-success-color;
        & .close {
            background: darken($base-success-color, 50%);
        }
    }
    &.alert-info {
        color: $base-light-color;
        background: $base-info-color;
        & .close {
            background: darken($base-info-color, 50%);
        }
    }
    &.alert-warning {
        color: $base-light-color;
        background: $base-warning-color;
        & .close {
            background: darken($base-warning-color, 50%);
        }
    }
    &.alert-danger {
        color: $base-light-color;
        background: $base-danger-color;
        & .close {
            background: darken($base-danger-color, 50%);
        }
    }
}

/* ========================================================================
 * message styles
 * ======================================================================== */

.message {
    padding: 20px;
    margin: 20px 0;
    border-left: 5px solid transparent;
    background: #f9f9f9;
    @include border-radius;
}
.message h4 {
    margin-top: 0;
    margin-bottom: 5px
}
.message h4 .icon {
    padding-bottom: 3px;
    margin-right: 5px;
}
.message p:last-child {
    margin-bottom: 0
}
.message code {
    border-radius: 3px
}
.message + .message {
    margin-top: -5px
}

.message {
    &-success {
        border-left-color: $base-success-color;
        & h4 {
            color: $base-success-color;
        }
    }
    &-info {
        border-left-color: $base-info-color;
        & h4 {
            color: $base-info-color;
        }
    }
    &-warning {
        border-left-color: $base-warning-color;
        & h4 {
            color: $base-warning-color;
        }
    }
    &-danger {
        border-left-color: $base-danger-color;
        & h4 {
            color: $base-danger-color;
        }
    }
}

/* ========================================================================
 * dropdown menu styles
 * ======================================================================== */

.dropdown-menu {
    border: none;
    background: #e4e4e4;
    @include border-radius;
    @include box-shadow;
    @include clearfix;
}

.dropdown-menu.arrow:before, .dropdown-menu.arrow.arrow-top-left:before {
    position: absolute;
    top: -5px;
    left: 15px;
    right: auto;
    display: inline-block;
    border-right: 6px solid transparent;
    border-bottom: 6px solid #e4e4e4;
    border-left: 6px solid transparent;
    content: '';
}

.dropdown-menu.arrow.arrow-top-right:before {
    left: auto;
    right: 15px;
}

.dropdown-menu.dark {
    background: $dropdown-menu-dark-background-color;
    color: $dropdown-menu-dark-color;
    @include border-radius;
    @include box-shadow;
}

.dropdown-menu.dark a {
    color: $dropdown-menu-dark-color;
}


.dropdown-menu.dark.arrow:before {
    border-bottom-color: $dropdown-menu-dark-background-color;
}

.dropdown-menu.tiles {
    padding: 4px;
    max-width: 385px;
}

.dropdown-menu.tiles > li {
    padding: 0;
    list-style: none;
    display: inline-block;
    float: left;
}

.dropdown-menu.tiles li a {
    display: block;
    margin: 4px;
    padding: 5px;
    list-style: none;
    width: 85px;
    height: 85px;
    text-align: center;
    vertical-align: text-bottom;
    color: $dropdown-menu-dark-tiles-color;
    text-decoration: none;
    background: $dropdown-menu-dark-tiles-background-color;

    &:hover {
        background: $dropdown-menu-dark-tiles-hover-background-color;
    }
}

.dropdown-menu.tiles li a .icon {
    display: block;
    font-size: 35px;
    margin: 3px 0 7px;
    height: 35px;
}

.dropdown-menu.tiles li a .name {
    display: block;
    line-height: 14px;
    font-size: 12px;
    height: 28px;
    overflow: hidden;
}

.dropdown-submenu {
    position:relative;
}

.dropdown-submenu > .dropdown-menu {
    top:0;
    left:100%;
    margin-top:-6px;
    margin-left:-1px;
}

.dropdown-submenu:hover > .dropdown-menu {
    display:block;
}

.dropdown-submenu > a:after {
    display:block;
    content:" ";
    float:right;
    width:0;
    height:0;
    border-color:transparent;
    border-style:solid;
    border-width:5px 0 5px 5px;
    border-left-color:#cccccc;
    margin-top:5px;
    margin-right:-10px;
}

.dropdown-submenu:hover > a:after {
    border-left-color:#ffffff;
}

.dropdown-submenu.pull-left {
    float:none;
}

.dropdown-submenu.pull-left > .dropdown-menu {
    left:-100%;
    margin-left:10px;
}

/* ========================================================================
 * loading styles
 * ======================================================================== */

.loading {
    position: relative;
}

.loading[data-loading-style=overlay] .loading-bg {
    background: $loading-background-color;
    position: absolute;
    height: 100%;
    width: 100%;
    z-index: 10000000;
    @include opacity($loading-background-opacity);
}

.loading[data-loading-style=icon-only] .loading-bg {
    display: none;
}

.loading[data-loading-inverse=true] .loading-bg {
    background: $loading-inverse-background-color;
}

.loading .loading-animation {
    position: absolute;
    z-index: 10000001;
    top: 50%;
    left: 50%;
    width: 100px;
    height: 75px;
    text-align: center;
    @include transform(translate(-50%, -50%));
}
.loading .loading-animation .logo img {
    max-width: $loading-image-icon-max-width;
}


.loading .loading-animation .logo:before {
    //content: url("../images/loading.svg");
}

.loading .loading-animation .logo {
    position: relative;
    width: 50px;
    margin: 0 auto;
}

.loading .loading-animation .logo .pulse-line,
.loading .loading-animation .logo .circle {
    fill: none;
    stroke: $loading-color;
}

.loading[data-loading-inverse=true] .loading-animation .logo .pulse-line,
.loading[data-loading-inverse=true] .loading-animation .logo .circle {
    stroke: $loading-inverse-color;
}

.loading .loading-animation .logo .circle {
    stroke-dasharray: 100;
    @include opacity(0.5);
}

.loading .loading-animation .logo .pulse-line {
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: dash 4s linear  infinite;
    @include opacity(0);
}

@keyframes dash {
    0% {
        @include opacity(0.9);
    }
    10% {
        stroke-dashoffset: 200;
        @include opacity(0.9);
    }
    70% {
        stroke-dashoffset: 500;
        @include opacity(0.9);
    }
    80% {
        @include opacity(0);
    }
    100% {
        @include opacity(0);
    }
}

.loading .loading-animation .logo .signal {
    border: 5px solid $loading-color;
    border-radius: 50px;
    height: 50px;
    width: 50px;
    @include opacity(0);
    position: absolute;
    top: 0;
    animation: pulsate 4s ease-out infinite;
    animation-delay: 1.5s;
    @include transform(translate(-50%, -50%));
}

@keyframes pulsate {
    0%, 30%  {
        @include opacity(0);
        @include transform(scale(0.9));
    }
    40% {
        @include opacity(1);
    }
    60% {
        @include opacity(0);
        @include transform(scale(1.2));
    }
}

.loading .loading-animation p {
    color: $loading-color;
    text-align: center;
    font-size: 11px;
    margin-top: 4px;
    text-transform: uppercase;
}

.loading[data-loading-inverse=true] .loading-animation p {
    color: $loading-inverse-color;
}

/* ui fixes */
#dp_swf_engine {
    display: none;
}

/* ========================================================================
 * form styles
 * ======================================================================== */

.form-horizontal {
    max-width: $form-control-max-width;
}

.control-label {
    font-weight: 400;
}

.input-group-btn .control-label {
    font-size: 14px;
    padding-top: 0;
    margin: 0 5px;
}

.input-group-btn .btn {
    &,
    &:hover,
    &:focus {
        border-color: #ccc;
    }
}

.form-control, .btn {
    @include border-radius;
    @include box-shadow;
}

a.btn, .btn {
    text-decoration: none;

    & .icon-caret {
        padding: 0 0 0 8px;
        margin-left: 5px;
        border-left: 1px solid #e4e4e4;
    }
    &.active, &:active {
        @include box-shadow;
    }
    &:hover {
        text-decoration: none;
        background: #eee;
    }
}

.btn-default {
    &, &:focus{
        color: $button-default-color;
        background-color: $button-default-background-color;
        border-color: $button-default-border-color;
    }

    &:hover {
        background-color: $button-default-hover-background-color;
        border-color: $button-default-hover-border-color;
    }
}

.btn-primary {
    &, &:focus {
        color: $button-primary-color;
        background-color: $button-primary-background-color;
        border-color: $button-primary-border-color;
    }

    &:hover {
        background-color: $button-primary-hover-background-color;
        border-color: $button-primary-hover-border-color;
    }
}

.btn-bordered {
    &, &:focus, &:hover {
        border: 1px solid #ccc;
    }
}

.btn-group > .btn-label {
    position: relative;
    float: left;
    color: $base-dark-color;
    background-color: transparent;
    display: inline-block;
    padding: 6px 12px;
    margin-bottom: 0;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.42857143;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    background-image: none;
    border: 1px solid transparent;

    &.btn-bordered {
        border-color: #e4e4e4;
        margin-left: -1px;
        margin-right: -1px;
    }
}

.remove-icon-ring-on-hover:hover .fw-ring {
    display: none;
}

.has-form-control-btn {
    position: relative;
}

.form-control-btn {
    &,
    &:focus,
    &:active,
    &:hover {
        position: absolute;
        top: 0;
        right: 0;
        display: block;
        width: 34px;
        height: 34px;
        line-height: 34px;
        text-align: center;
        background: transparent;
        border: none;
        z-index: 5;
        opacity: 0.7;
        font-size: 14px;
    }

    &:hover {
        opacity: 1;
    }
}

.form-control {
    width: 100%;

    &-xs {
        min-width: calc(#{$form-control-max-width}/12);
    }
    &-sm {
        min-width: calc(#{$form-control-max-width}/9);
    }
    &-md {
        min-width: calc(#{$form-control-max-width}/6);
    }
    &-lg {
        min-width: calc(#{$form-control-max-width}/2);
    }
}

input[type=number].form-control {
    padding: 0 0 0 12px;
}

.input-wrap {
    width: 100%;
}

.form-control:focus {
    @include box-shadow
}

.input-wrap .btn.wrap-input-right {
    border-left: none;
}

.input-group-addon {
    @include border-radius;
}

.file-upload-control input[type=file] {
    display: none;
}

.file-upload-control input[readonly] {
    background-color: white !important;
    cursor: text !important;
}

@media only screen and (max-width: 768px) {
    .input-group.res-wrap {
        &,
        & .form-control,
        & .control-label,
        & .input-group-btn  {
            min-width: 100%;
            display: block;
            float: none;
        }
    }

    .input-group.res-wrap .control-label {
        line-height: 34px;
        margin: 5px 0 0 0;
    }

    .form-control {
        &-xs {
            min-width: calc(#{$form-control-max-width}/24);
        }
        &-sm {
            min-width: calc(#{$form-control-max-width}/18);
        }
        &-md {
            min-width: calc(#{$form-control-max-width}/12);
        }
        &-lg {
            min-width: calc(#{$form-control-max-width}/4);
        }
    }
}

/* ========================================================================
 * table styles
 * ======================================================================== */

.table thead th {
    font-weight: 300;
}

.table .form-control {
    min-width: 100%;
}

@media only screen and (max-width: 767px) {
    .table-responsive table,
    .table-responsive thead,
    .table-responsive tbody,
    .table-responsive th,
    .table-responsive td,
    .table-responsive tr {
        display: block;
    }

    .table-responsive thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }

    .table-responsive tr {
        border: 1px solid #ccc;
    }

    .table-responsive.table-striped {
        border: none;
    }

    .table-responsive tbody > tr > td {
        border: none;
        border-bottom: 1px solid #eee;
        position: relative;
        padding-left: 50%;
        white-space: normal;
        text-align:left;
    }

    .table-responsive tr > td:before {
        position: absolute;
        top: 6px;
        left: 6px;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
        text-align:left;
        font-weight: bold;
    }

    .table-responsive tbody > tr > td:before {
        content: attr(data-title);
    }
}


/* ========================================================================
 * list table styles
 * ======================================================================== */

.table.list-table {
    min-width: 100%;
    display: block;
}

.table.list-table thead,
.table.list-table tbody {
    vertical-align: top;
}

.table.list-table {
    & > tbody > tr > td,
    & > tbody > tr > th,
    & > tfoot > tr > td,
    & > tfoot > tr > th,
    & > thead > tr > td,
    & > thead > tr > th {
        border: none;
        padding: 8px;
        vertical-align: middle;
        overflow: hidden;
        position: relative;
    }
    .h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6 {
        margin: 0;
    }
}

.table.list-table tr {
    border-bottom: 5px solid transparent;
}

.table.list-table > thead > tr.sort-row {
    display: none;
}

.table.list-table > tbody > tr:nth-of-type(odd),
.table.list-table > tbody > tr:nth-of-type(even) {
    background-color: transparent;
}

.table.list-table > tbody > tr.child ul {
    text-align: left;
    display: block;
}

.table.table-hover > tbody > tr:hover td:not(.dataTables_empty) {
    background: #e4e4e4 !important;

    &.fade-edge {
        @include fade-color(#e4e4e4);
    }
}

.table.table-selectable > tbody > tr:hover {
    cursor: pointer;
}

.table.table-selectable > tbody > tr:hover td:not(.dataTables_empty):first-child:before,
.table.table-selectable > tbody > tr.DTTT_selected td:not(.dataTables_empty):first-child:before {
    position: absolute;
    display: block;
    content: "";
    background-color: transparent;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    height: .65rem;
    width: 1.3rem;
    z-index: 102;
    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);
    right: 0.3rem;
    left: auto;
    top: 0.3rem;
}

.table.table-selectable.grid-view > tbody > tr.DTTT_selected td:not(.dataTables_empty):first-child {
    border: 5px solid #007d85;
}

.table.table-selectable:not(.grid-view) > tbody > tr.DTTT_selected td:not(.dataTables_empty) {
    background: #2C313B !important;
    color: #fff;
}

.table.table-selectable > tbody > tr:hover td:not(.dataTables_empty):first-child:after,
.table.table-selectable > tbody > tr.DTTT_selected td:not(.dataTables_empty):first-child:after,
.table.table-selectable > tbody > tr[data-type=selectable] td:not(.dataTables_empty):first-child:after {
    position: absolute;
    display: block;
    border-top: 32px solid #007d85;
    border-left: 32px solid transparent;
    right: 0;
    content: "";
    top: 0;
    z-index: 101;
}

.table.table-selectable > tbody > tr[data-type=selectable]:not(:hover):not(.DTTT_selected) td:not(.dataTables_empty):first-child:after {
    border-top-color: #e4e4e4;
}


.table.list-table thead tr.bulk-action-row {
    display: block;
    margin: 0 15px;

    & > th, & > td {
        display: block !important;
    }

    & > th > div, & > td > div,
    & > th > span, & > td > span,
    & > th > ul, & > td > ul {
        margin: 0 -10px;
    }
}

.table.list-table > thead.block > tr > td:not(:empty):before,
.table.list-table > thead.block > tr > th:not(:empty):before {
    content: attr(data-for);
}

.table.list-table:not(.grid-view) .content-fill {
    width: 1%;
}

.table.list-table:not(.grid-view) {
    & > tbody > tr > td,
    & > tbody > tr > th{
        background: #f5f5f5;

        &.fade-edge:after {
            display: none;
        }
    }
}

.table.list-table:not(.grid-view) tbody {
    margin: 0 15px;
}

.table.list-table:not(.grid-view) .thumbnail {
    max-width: 60px;
    min-width: 60px;
}

.table.list-table.grid-view > thead > tr {
    width: auto;
}

.table.list-table.grid-view {
    & > tbody > tr > td,
    & > tbody > tr > th,
    & > tfoot > tr > td,
    & > tfoot > tr > th {
        display: block;
        white-space: nowrap;
        padding: 10px 0;
    }
    & > tbody > tr > td[data-grid-label]:before,
    & > tbody > tr > th[data-grid-label]:before {
        content: attr(data-grid-label)+':';
        font-weight: 600;
        margin-right: 8px;
    }
    & > tbody > tr.header-row {
        display: none;
    }
    & > thead > tr > td,
    & > thead > tr > th {
        display: inline-block;
    }
    & > thead > tr > td:not(:empty):before,
    & > thead > tr > th:not(:empty):before {
        content: attr(data-for);
    }
    .hidden-on-grid-view {
        display: none;
    }
    .padding-reduce-on-grid-view {
        padding: 2px;
    }
    .text-left-on-grid-view {
        text-align: left;
    }
    .text-right-on-grid-view {
        text-align: right;
    }
    .text-center-on-grid-view {
        text-align: center;
    }
}

.table.list-table {
    width: auto;
    display: block;
    margin-right: -15px;
    margin-left: -15px;

    & > thead,
    & > tbody,
    & > tfoot {
        display: block;
    }
}

.table.list-table.grid-view tr {
    display: inline-block;
}

.table.list-table.grid-view > tbody > tr {
    padding: 15px 15px 0;
}

.table.list-table.grid-view .filter-row,
.table.list-table thead.block .filter-row {
    background: #e4e4e4;
    margin: 0 15px;
    padding: 15px;
    display: block;
}

.table.list-table.grid-view .filter-row th:empty,
.table.list-table thead.block .filter-row th:empty {
    display: none;
}

.table.list-table.grid-view tr td {
    padding: 0;
}

@media (max-width:767px){
    .table.list-table {
        & > thead > tr.filter-row,
        & > thead > tr.filter-row > td,
        & > thead > tr.filter-row > th {
            display: block;
        }
    }
}
@media (min-width:320px) and (max-width:479px){
    .table.list-table.grid-view tr {
        width: 100%;
    }
}
@media (min-width:480px) and (max-width:767px){
    .table.list-table.grid-view tr {
        width: 50%;
    }
    .table.list-table:not(.grid-view) .content-fill {
        width: auto;
    }
}
@media (min-width:768px) and (max-width:991px){
    .table.list-table.grid-view tr {
        width: 33.3%;
    }
}
@media (min-width:992px) and (max-width:1199px){
    .table.list-table.grid-view tr {
        width: 20%;
    }
}
@media (min-width:1200px){
    .table.list-table.grid-view tr {
        width: 10%;
    }
}

/* ========================================================================
 * data table styles
 * ======================================================================== */

table.dataTable thead .sorting:after,
table.dataTable thead .sorting_asc:after,
table.dataTable thead .sorting_desc:after {
    font-family: $font-icons;
}

.dataTables_wrapper ul.sort-list li a:before,
.dataTables_wrapper ul.sort-list li a.sorting_asc:before,
.dataTables_wrapper ul.sort-list li a.sorting_desc:before {
    font-family: $font-icons;
    margin-right: 10px;
    font-size: 11px;
    @include opacity(1);
}

.dataTables_wrapper ul.sort-list li a:before {
    @include opacity(0.2);
}

table.dataTable thead .sorting:after,
.dataTables_wrapper ul.sort-list li a:before {
    content: "\e673";
}

table.dataTable thead .sorting_asc:after,
.dataTables_wrapper ul.sort-list li a.sorting_asc:before {
    content: "\e64b";
}

table.dataTable thead .sorting_desc:after,
.dataTables_wrapper ul.sort-list li a.sorting_desc:before {
    content: "\e663";
}

table.dataTable thead .sorting {
    padding-right: 30px !important;
}

table.dataTable thead .no-sort:after {
    display: none!important;
}

table.dataTable thead .no-sort {
    pointer-events: none!important;
    cursor: default!important;
}

table.dataTable tr.filter-row td,
table.dataTable tr.filter-row th {
    padding: 0 8px 10px;
}

.dataTables_wrapper > div.row > div {
    text-align: left;
}

.dataTables_filter,
.dataTables_toolbar,
.dataTables_length,
.dataTables_info {
    text-align: left;
    float: left;
}

.dataTables_toolbar,
.dataTables_paginate {
    float: right;
}

.dataTablesTop,
.dataTablesBottom {
    @include clearfix;
    margin: 0;
}

.dataTablesBottom .dataTables_info {
    padding: 4px 0 0 10px;
    margin-left: 10px;
    border-left: 1px solid #e4e4e4;
}

.dataTables_filter .search-icon {
    position: relative;
    z-index: 1;
    right: -10px;
    top: 0;
    color: #7B7B7B;
    cursor: pointer;
}

.dataTables_filter input {
    padding: 0 15px 0 35px;
    min-width: 300px;
    margin: 0 0 0 -14px !important;
}

.table.dataTable tbody tr.active td,
.table.dataTable tbody tr.active th,
.table.dataTable tbody tr.active:hover td,
.table.dataTable tbody tr.active:hover th {
    background-color: $primary-color !important;
}


.table.dataTable tbody tr td.dataTables_empty {
    overflow: visible;
    cursor: default;
    background: none;
    padding: 0;
}

table.dataTable.dtr-inline.collapsed > tbody > tr {
    & > td:first-child:before,
    & > th:first-child:before {
        top: 50%;
        left: 10px;
        margin-top: -8px;
    }
    & > td:first-child:first-child,
    & > th:first-child:first-child {
        padding-left: 40px !important;
    }
}

/* ========================================================================
 * thumbnail styles
 * ======================================================================== */

.thumbnail {
    @include border-radius;
}

.thumbnail.icon {
    border: none;
    margin: 0;
    background: $primary-color;
    color: #fff;
    text-align: center;
    overflow: hidden;
    @include square-ratio(1,1);
}

.thumbnail.icon .square-element:before {
    position: absolute;
    top: 50%;
    left: 50%;
    @include transform(translate(-50%, -50%));
}

.thumbnail.icon img {
    width: 100%;
}

/* ========================================================================
 * thumbnail list styles
 * ======================================================================== */

.thumbnail-list {
    @include reset-default;
    @include clearfix;
}

.thumbnail-list li {
    float: left;
}


/* ========================================================================
 * pagination styles
 * ======================================================================== */

.pagination > li {
    &:first-child > a,
    &:first-child > span,
    &:last-child > a,
    &:last-child > span {
        @include border-radius;
    }

    & > a,
    & > a:focus,
    & > a:hover,
    & > span,
    & > span:hover{
        text-decoration: none;
        color: $primary-color;
    }
}

.pagination > .active {
    & > a,
    & > a:focus,
    & > a:hover,
    & > span,
    & > span:focus,
    & > span:hover {
        background: $primary-color;
        border-color: $primary-color;
    }
}

.pagination > .disabled {
    & > a,
    & > a:focus,
    & > a:hover,
    & > span,
    & > span:focus,
    & > span:hover {
        display: none;
    }
}

/* ========================================================================
 * panel styles
 * ======================================================================== */

.panel-group .panel, .panel-heading, .panel-footer, .panel-body {
    @include border-radius;
    padding: 0;
}

.panel {
    @include box-shadow;
    border: none;
}

.panel-default > .panel-heading {
    background: transparent;
    font-size: 24px;
    font-weight: 300;
    border-bottom: 1px solid #e4e4e4;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

/* ========================================================================
 * noty styles
 * ======================================================================== */

#noty_topRight_layout_container {
    position: absolute !important;
}

#noty_topRight_layout_container, #noty_topLeft_layout_container {
    margin-top: 100px !important;
}

.noty_bar {
    height: auto;
    border: none;
    padding: 10px 20px;
}

.noty_container_type {
    &_notification {
        background-color: $base-dark-color;
        color: $base-light-color;
    }
    &_warning {
        background-color: #ffeaa8;
        color: #826200;
    }
    &_error {
        background-color: #e74c3c;
        color: $base-light-color;
    }
    &_information {
        background-color: #78c5e7;
        color: $base-light-color;
    }
    &_success {
        background-color: #40d47e;
        color: $base-light-color;
    }
}

@media only screen and (max-width: 768px) {
    #noty_topRight_layout_container, .noty_container_type_information, #noty_topLeft_layout_container, .noty_bar {
        width: 100% !important;
        left: 0;
        right: 0;
    }
}

/* ========================================================================
 * tiles styles
 * ======================================================================== */

ul.tiles {
    @include reset-default;
}

ul.tiles li {
    display: inline-block;
}

ul.tiles li.square {
    min-width: 80px;
    @include square-ratio(1,1);
}

ul.tiles li a {
    text-decoration: none;
    padding: 5px;
    background: #f3f3f3;
    color: $base-dark-color;
    display: block;
    overflow: hidden;
    line-height: 1.2em;
    white-space: normal;
    text-transform: capitalize;
}

ul.tiles .icon {
    display: block;
    font-size: 15px;
    margin: 0 auto 5px;
}

/* ========================================================================
 * modal popup styles
 * ======================================================================== */

.modal-open {
    padding: 0 !important;
}

.modal {
    z-index: 100000001;
    padding: 0 !important;
}

.modal-backdrop {
    z-index: 100000000;
}

.modal-content {
    background: $base-dark-color;
    color: $base-light-color;
    @include border-radius;
    @include box-shadow;
}

.modal-header {
    border-bottom: none;
    padding: 15px 15px 0;
}

.modal-header .close {
    color: $base-light-color;
    text-shadow: none;
    opacity: 0.8;
}

.modal-body {
    padding: 0 15px;
}

.modal-dialog {
    margin: 80px auto;
}

.modal-footer {
    border-top: none;
}

@media only screen and (max-width: 768px) {
    .modal {
        padding: 0 15px !important;
    }
}

@media only screen and (min-width: 1280px){
    .modal-dialog {
        width: 1000px;
    }
}

/* ========================================================================
 * list group styles
 * ======================================================================== */

.list-group-item:first-child,
.list-group-item:last-child {
    @include border-radius;
}

a.list-group-item:hover {
    text-decoration: none;
}

.list-group-item.active, .active > .list-group-item {
    &,
    &:focus,
    &:hover {
        color: $base-light-color;
        background: $primary-color;
        border-color: $primary-color;
    }
}
.list-group-item.active a {
    color:#fff;
    text-decoration: none;
}

.list-group.nav > .list-group-item {
    padding: 0;
}

/* ========================================================================
 * tree styles
 * ======================================================================== */

.tree-view,
.tree-view ul {
    @include reset-default;
}

.tree-view ul {
    margin-left: 0.7em;
    position: relative;
}

.tree-view ul li {
    display: none;
}

.tree-view li[aria-expanded=true] > ul > li {
    display: list-item;
}

.tree-view li {
    margin: 0;
    padding: 0 2em;
    line-height: 2em;
    position: relative;
}

.tree-view .branch {
    cursor: pointer;
}

.tree-view li {
    & > .icon {
        font-family: $font-icons;
        font-style: normal;
        background: $primary-color;
        color: $base-light-color;
        height: 20px;
        width: 20px;
        text-align: center;
        line-height: 20px;
        font-size: 10px;
        display: inline-block;
        margin-right: 10px;
    }
    & > .icon:before {
        content: "\e687";
    }
    &[aria-expanded=true] > .icon:before {
        content: "\e685";
    }
}

.tree-view li a {
    &, &:hover {
        text-decoration: none;
    }
}

.tree-view li button {
    &:active,
    &:focus {
        cursor: pointer;
        text-decoration: none;
        border: none;
        background: transparent;
        @include reset-default;
    }
}

.tree-view.tree-view-lines ul {
    &:before {
        content: "";
        display: block;
        width: 0;
        position: absolute;
        top: 0;
        bottom: 15px;
        left: 0;
        border-left: 1px solid;
    }
    & li:before {
        content: "";
        display: block;
        width: 20px;
        height: 0;
        border-top: 1px solid;
        margin-top: -1px;
        position: absolute;
        top: 1em;
        left: 0;
    }
}

.tree-view .checkbox,
.tree-view .radio {
    margin: 0;
    display: inline-block;
}

.tree-view .checkbox input[type=checkbox],
.tree-view .checkbox-inline input[type=checkbox],
.tree-view .radio input[type=radio],
.tree-view .radio-inline input[type=radio] {
    margin-top: 6px;
}

/* ========================================================================
 * asset details styles
 * ======================================================================== */

.asset-image {
    max-width: 150px;
    background: $primary-color;
    float: none;
}

.asset-desc .asset-name {
    font-size: 24px;
    margin-bottom: 0;
}

.asset-desc .asset-publisher {
    font-size: 14px;
    margin-bottom: 20px;
}

/* ========================================================================
 * switch styles
 * ======================================================================== */

.switch {
    display: inline-block;
    width: 40px;
    cursor: pointer;
    position: relative;
    margin-top: -4px;

    & > input[type=checkbox] {
        position: absolute;
        opacity: 0;

        &:checked + .helper + .text {
            display: inline-block;
        }

        & + .helper:after {
            position: absolute;
            left: 18px;
            top: -2px;
            display: block;
            content: "";
            width: 24px;
            height: 24px;
            cursor: pointer;
            background: $switch-handler-active-color;
            z-index: 2;
            border-radius: 12px;

            -webkit-transition: left 0.2s ease-in-out;
            -moz-transition: left 0.2s ease-in-out;
            -o-transition: left 0.2s ease-in-out;
            transition: left 0.2s ease-in-out;
        }

        &:not(:checked) + .helper:after {
            left: 1px !important;
            background: $switch-handler-inactive-color;
        }

        &:not(:checked) + .helper:before {
            background: $switch-inactive-background-color !important;
        }

        &:disabled + .helper:after {
            cursor: default !important;
            background: $switch-handler-disabled-color !important;
        }

        &:disabled + .helper:before {
            cursor: default !important;
            background: $switch-disabled-background-color !important;
        }
    }

    & .helper {
        padding-left: 52px;
        position: relative;

        &:before {
            position: absolute;
            left: 0;
            top: 2px;
            display: block;
            content: "";
            width: 40px;
            height: 16px;
            cursor: pointer;
            background: $switch-active-background-color;
            margin-left: 2px;
            z-index: 1;
            border-radius: 8px;
        }
    }

    & .text {
        display: none;
        margin-left: 5px;
        font-weight: 100;
    }
}

/* ========================================================================
 * radio button styles
 * ======================================================================== */

.radio {
    display: inline-block;
    margin-right: 10px;
    margin-bottom: 0;
    margin-top: 0;
    cursor: pointer;
    font-weight: 300;

    & > input[type=radio] {
        position: absolute;
        opacity: 0;

        &:checked + .helper:after {
            position: absolute;
            display: block;
            content: "";
            color: $button-primary-background-color;
            z-index: 2;
            font-size: 16px;
            font-weight: bold;
            left: 5px;
            margin-left: 0;
            top: 50%;
            margin-top: -5px;
            background-color: $button-primary-background-color;
            width: 10px;
            height: 10px;
            border-radius: 100%;
        }

        &:checked + .helper:before {
            border: 2px $button-primary-background-color solid;
        }

        &:disabled + .helper:before {
            cursor: default;
            background: #e6e6e6;
        }

        &:disabled + .helper:after {
            background-color: #8a8a8a;
        }

        &:not(:disabled) + .helper:before {
            border-color: #919191;
        }

        &:not(:disabled) + .helper:before {
            border-color: #919191;
        }
    }

    & .helper {
        padding-left: 26px;
        padding-top: 1px;
        position: relative;

        &:before {
            position: absolute;
            display: block;
            height: 20px;
            width: 20px;
            content: "";
            text-indent: -9999px;
            border: 2px #d9d9d9 solid;
            z-index: 1;
            opacity: 1;
            top: -1px;
            left: 0;
            border-radius: 100%;
        }
    }
}

/* ========================================================================
 * checkbox styles
 * ======================================================================== */

.checkbox {
    display: inline-block;
    margin: 0 10px 0 0;
    cursor: pointer;
    font-weight: 300;

    & > input[type=checkbox] {
        position: absolute;
        opacity: 0;

        &:checked + .helper:before {
            border: 2px $button-primary-background-color solid;
        }

        &:checked + .helper:after {
            position: absolute;
            display: block;
            content: "\e617";
            font-size: 7pt;
            height: 16px;
            width: 16px;
            line-height: 16px;
            z-index: 2;
            top: 2px;
            margin-top: 0;
            left: 2px;
            margin-left: 0;
            text-align: center;
            background: $button-primary-background-color;
            color: #fff;
            font-family: font-wso2;
        }

        &:not(:checked) + .helper:after {
            display: none;
        }

        &:disabled + .helper:before {
            cursor: default;
            background: #e6e6e6;
        }

        &:disabled + .helper:after {
            color: #8a8a8a;
        }

        &:not(:disabled) + .helper:before {
            border-color: #526A84;
        }

        :not(:disabled) + .helper:before {
            border-color: #526A84;
        }
    }

    & .helper {
        padding-left: 23px;
        position: relative;

        &:before {
            position: absolute;
            display: block;
            height: 20px;
            width: 20px;
            content: "";
            text-indent: -9999px;
            border: 2px #eaf0f1 solid;
            z-index: 1;
            opacity: 1;
            top: 0;
            left: 0;
        }
    }
}

@media (min-width:768px) {
    .tab-content > .tab-pane {
        display: none !important;
    }

    .tab-content > .active {
        display: block !important;
    }
}